﻿@model BrnMall.Web.StoreAdmin.Models.StoreClassListModel

@section header{
    <title>店铺分类-店铺管理</title>
    <link type="text/css" rel="stylesheet" href="/admin_store/css/site.css"/>
    <script type="text/javascript" src="/admin_store/scripts/jquery.js"></script>
    <script type="text/javascript" src="/admin_store/scripts/showlist.js"></script>
    <style>
        .bottom-borders{border-bottom:1px dashed #ff8427;}
    </style>
}

@section body{
    <h1 class="rightH1">
        微信小程序 &gt; 店铺管理 &gt; <span class="rightH1-cur">店铺分类</span> 
        <div class="right">
            <a href="@Url.Action("addstoreclass")" class="menuBT"><img src="/admin_store/images/add.jpg" />添加</a>
            <div class="clear"></div>
        </div>
        <div class="clear"></div>
    </h1>
<div class="table_top"></div>

<div id="categoryTree" style="padding:0px; margin: 0;">
    <table width="100%">
        <thead>
            <tr>
                <th align="left" style="width:73%">名称</th>
                <th width="30" align="left">排序</th>
                <th width="76" align="left">管理操作</th>
            </tr>
        </thead>
    </table>
    <div style="margin:auto;margin-left:10px; margin-right:20px;">
        <table width="100%">
            <thead>
                <tr>
                    <td align="left" style="width:75%"></td>
                    <td width="40" align="left"></td>
                    <td width="76" align="left"></td>
                </tr>
            </thead>
            <tbody>

                @foreach (StoreClassInfo info in Model.StoreClassList)
{
                    <tr>
                        @if (info.HasChild != 0)
                {
                            <th class="bottom-borders">@Html.Raw(CommonHelper.GetHtmlSpan(info.Layer - 1))<span></span>@info.Name</th>
                            <td class="bottom-borders">@info.DisplayOrder</td>
                            <td class="bottom-borders">
                                <a href="@Url.Action("editstoreclass", new { storeCid = info.StoreCid })" class="editOperate">修改</a>
                                @if (info.HasChild == 0)
                        {
                                    <span class="btn-line">|</span>
                                    <a href="@Url.Action("delstoreclass", new { storeCid = info.StoreCid })" class="deleteOperate">删除</a>

                        }
                            </td>
                }
                else
                {
                            <th>@Html.Raw(CommonHelper.GetHtmlSpan(info.Layer - 1))<span></span>@info.Name</th>
                            <td>@info.DisplayOrder</td>
                            <td>
                                <a href="@Url.Action("editstoreclass", new { storeCid = info.StoreCid })" class="editOperate">修改</a>
                                @if (info.HasChild == 0)
                        {
                                    <span class="btn-line">|</span>
                                    <a href="@Url.Action("delstoreclass", new { storeCid = info.StoreCid })" class="deleteOperate">删除</a>

                        }
                            </td>
                }
                    </tr>
        }
            </tbody>

        </table>
    </div>
</div>

<div class="table_bottom"></div>
    }
